package reentlock;

public class ReentDemo {
    public static void main(String[] args) {
        DemoReentryLock demoReentryLock = new DemoReentryLock();
        new Thread(() -> {
            System.out.println("我开始上锁了");
            demoReentryLock.lock();
            demoReentryLock.lock();
            demoReentryLock.unlock();
            demoReentryLock.unlock();
            System.out.println("已经全部解锁");
        }).start();

    }


}
